package ywpt.components.acegi.domain;

import java.util.HashSet;
import java.util.Set;

public class Function implements java.io.Serializable {
	private static final long	serialVersionUID	= 8114108216579341676L;
	private Long				id;
	private Integer				version;
	private Function			parent;
	private String				functionCode;
	private String				functionName;
	private String				url;
	private String				description;
	private Set<Function>		children			= new HashSet<Function>(0);
	private Set<Role>			roles				= new HashSet<Role>(0);

	public Function() {
	}

	public Function(Function parent, String functionCode, String functionName, String url, String description, Set<Function> children) {
		this.parent = parent;
		this.functionCode = functionCode;
		this.functionName = functionName;
		this.url = url;
		this.description = description;
		this.children = children;
	}

	// Property accessors
	public Long getId() {
		return this.id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public Integer getVersion() {
		return this.version;
	}

	public void setVersion(Integer version) {
		this.version = version;
	}

	public Function getParent() {
		return this.parent;
	}

	public void setParent(Function parent) {
		this.parent = parent;
	}

	public Set<Role> getRoles() {
		return roles;
	}

	public void setRoles(Set<Role> roles) {
		this.roles = roles;
	}

	public String getFunctionCode() {
		return this.functionCode;
	}

	public void setFunctionCode(String functionCode) {
		this.functionCode = functionCode;
	}

	public String getFunctionName() {
		return this.functionName;
	}

	public void setFunctionName(String functionName) {
		this.functionName = functionName;
	}

	public String getUrl() {
		return this.url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public String getDescription() {
		return this.description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public Set<Function> getChildren() {
		return this.children;
	}

	public void setChildren(Set<Function> children) {
		this.children = children;
	}
}